
<div class="pbd scheduled dashboardScroll">
<% if(goodsBase.dateType==1) {%>
    <div class="m-travel-date" node-name="switchdate" data-id="<%= goodsBase.id %>" data-title="<%= goodsBase.title %>" data-thumb="<%= imgsite %><%= goodsBase.thumb %>" data-description="<%= goodsBase.description %>">
        <div class="label"><i class="icon-clock"></i> <span>出游日期</span></div>  <div> <strong><%=goodsBase.date%>&nbsp;星期<%=weeks[goodsBase.week]%></strong></div>  
    </div>
<% }else if(goodsBase.dateType==2){ %>
    <div class="valid-date">有效期  <%=goodsBase.effectStart.replace(/\s\d+:\d+:\d+/,"")%>至<%=goodsBase.effectEnd.replace(/\s\d+:\d+:\d+/,"")%></div> 
<% }else if(goodsBase.dateType==3){ %>
   <%  var startgap = goodsBase.effectStart; %>
   <%  var endgap = goodsBase.effectEnd; %>
   <%  var timegap = endgap-startgap; %>
	<% if(startgap>0) {%>
		<% if(goodsBase.effectType==1) {%>
			<div class="valid-date">购买后<%=startgap%>天生效，有效期<%=endgap%>天</div> 
		<% }else{ %>

		  <div class="valid-date">购买后
			  <% if(startgap>=1440) {%>
				  <%=Math.floor(startgap/1440)%>天<% if(Math.floor((startgap%1440)/60)>0){ %><%= Math.floor((startgap%1440)/60)%>小时<% } %><% if(startgap%60){ %><%= startgap%60 %>分钟<% } %>
			   <% }else if(startgap>=60){ %>
					<% if(Math.floor(startgap/60)>0){ %><%=Math.floor(startgap/60)%><% } %>小时<% if(Math.floor(startgap%60)>0){ %><%=Math.floor(startgap%60)%>分钟<% } %>
			   <% }else{ %>
					<%=startgap%>分钟
			   <% } %>
		   生效，有效期 			
			<% if(timegap>=1440) {%><%=Math.floor(timegap/1440)%>天<% if(Math.floor((timegap%1440)/60)>0){%><%= Math.floor((timegap%1440)/60)%>小时<% } %><% if(Math.floor(timegap%60)>0){%><%= timegap%60 %>分钟<% } %><% }else if(timegap>=60){ %><% if(Math.floor(timegap/60)>0){%><%=Math.floor(timegap/60)%>小时<% } %><% if(Math.floor(timegap%60)>0){%><%=Math.floor(timegap%60)%>分钟<% } %><% }else{ %><% if(timegap>0){%><%=timegap%>分钟<% } %><% } %>
		   </div> 
		<% } %>
	<% }else{ %>
		<div class="valid-date">购买后立即生效，有效期
		<% if(goodsBase.effectType==1) {%>
			<%=endgap%>天
		<% }else{ %>			
			<% if(timegap>=1440) {%><%=Math.floor(timegap/1440)%>天<% if(Math.floor((timegap%1440)/60)>0){%><%= Math.floor((timegap%1440)/60)%>小时<% } %><% if(Math.floor(timegap%60)>0){%><%= timegap%60 %>分钟<% } %><% }else if(timegap>=60){ %><% if(Math.floor(timegap/60)>0){%><%=Math.floor(timegap/60)%>小时<% } %><% if(Math.floor(timegap%60)>0){%><%=Math.floor(timegap%60)%>分钟<% } %><% }else{ %><% if(timegap>0){%><%=timegap%>分钟<% } %><% } %>
		<% } %>
		</div> 
	<% } %>
<% } %>
    <div node-name="append" id="appendTicket">
        <div class="wrap-box">
            <div class="m-travel-title">
                <div class="title"><%=title%></div>
                <div class="price"><sub>&yen;</sub><%=goodsBase.price%></div>
            </div>
            <div class="hr"></div>
            <div class="m-buy-qunit">
                <div class="title">购买数量<span> <% if(goodsBase.userDayMaxSaleNum!=0) {%><span class="limit">(同一用户每日限购<%=goodsBase.userDayMaxSaleNum%>张)</span><% } %></span></div>
				<div class="quantity-wrap">
                <div class="quantity-form" node-name="spinner" data-event="bind" data-trigger="spinner">
					<a href="javascript:;" class="num-btn increment" node-name="down" data-action="send" data-spin="down"></a><input type="text" readonly="readonly" autocomplete="off" data-event="count" class="quantity" data-title="<%=title%>" data-goodsid="<%=id%>" data-goodsno="<%=goodsno%>" id="firstTicket" data-time="<%=goodsBase.date%>" data-price="<%=goodsBase.price%>" data-min="<%=goodsBase.singleBuyNum%>" data-max="<%=goodsBase.userDayMaxSaleNum%>" value="<%=goodsBase.singleBuyNum%>" node-name="quantity" data-ruler="quantity"/><a href="javascript:;" class="num-btn decrement" node-name="up" data-action="send" data-spin="up"></a>
                </div>
				</div>
            </div>
			<div class="hr"></div>
			<div class="show-detail" node-name="viewdetail"><div class="title">预定须知、商品详情</div><div class="dirview"><i class="icon-right"></i></div></div>
            <div class="ticket-list" id="storeTicket" node-name="storeNodes"></div>
        </div>
    </div>
    <div class="wrap-box m-imei">
		<form id="info_form">
			<div class="form-group" node-name="mobileRow"><div class="label">手机号码</div> <div class="item-feild"><input type="tel" class="form-control" value="" placeholder="接收凭证短信" name="mobile" node-name="mobile" tabindex="1" maxlength="11" /></div></div>
			<% if(goodsBase.needIdCard=="1") {%>
			<div class="hr" node-name="hrRow"></div>
			<div class="form-group" node-name="idcardRow"><div class="label">身份证号</div> <div class="item-feild"><input type="text" class="form-control" value="" placeholder="可刷身份证入园" name="idcard" node-name="idcard" tabindex="2" maxlength="18" /></div></div>
			<% } %>
		</form>
    </div>
	<div class="wrap-box couponmax" style="display:none;">
       <div class="coupon-title"><i class="icon-coupon"></i> <span>可使用优惠券</span></div>
	   <div class="coupon-list dashboardScroll" node-name="couponlist" data-page="2"></div>
	</div>
	<div class="cardpay" node-name="cardpay" style="display:none;">
		<div class="card-title">华侨城华支付</div>
		<div class="card-inner">
			<div class="card-list dashboardScroll" node-name="cardlist"></div>
		</div>
	</div>
</div> 
<div class="opt-full-btn"><button type="button" class="btn" node-name="submit"><span>提交订单</span> <span>&yen;</span><span node-name="totalprice" data-price="<%= goodsBase.price %>"><%= goodsBase.price*goodsBase.singleBuyNum %></span></button></div>
<div class="detail-layer" node-name="detailayer"><div class="detail-mask" node-name="detailmask"></div></div>
<% if(goodsBase.dateType==1) {%>
<div id="selectDate" class="m-datepicker" data-time="<%=goodsBase.date.replace(/-\d+$/,'')%>-<%= ocid %>" node-name="datepicker" style="display:none;">
   <div class="mask" node-name="mask"></div>
   <input type="hidden" node-name="selectday" />
   <div class="datepicker" node-name="datebox"></div>
</div>
<% } %>